<!DOCTYPE html>
<html lang="zh">
<head>
	<meta charset="UTF-8" />
	<meta name="viewport" content="width=device-width, initial-scale=1.0" />
	<meta http-equiv="X-UA-Compatible" content="ie=edge" />
	<title></title>
</head>
<body>

<input type="button" name="" id="submit" value="确定" />

<script src="/assets/js/jquery-3.2.1.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript">
    $(document).ready(function(){


        $("#submit").click(function(){
            var name = "商品5";
            $.ajax({
                type:"post",
                url:"{:url('admin/goods/editGoods')}",
                data:{
                    name:name,
                    goods_pic:"asdsa",
                },
                async:true,
                success:function(data){
                    console.log(data);
                },
                error:function(){
                    console.log("error");
                }
            });
        });


    });
</script>
</body>
</html>